
package com.hlkj.pay.gateway.order;
/*
 * Hlpay-Plus aggregate payment system.
 * Copyright (c) 2024-2025 Hlpay Team Copyright has the right of final interpretation.
 */

import javax.servlet.http.HttpServletRequest;

import com.hlkj.framework.common.pojo.CommonResult;
import com.hlkj.pay.dto.order.RefundOrderChannelResultDto;
import com.hlkj.pay.dto.order.notify.RefundOrderNotifyDto;
import com.hlkj.pay.infrastructure.model.order.PayOrderDO;
import com.hlkj.pay.infrastructure.model.order.RefundOrderDO;
import com.hlkj.pay.infrastructure.model.pay.ProviderChannelConfigDO;

/**
 * @author HlpayTeam
 * @date 2024/11/06 13:28
 */
public interface IChannelRefundOrderGateway {
	/**
	 * 是否支付退款
	 *
	 * @param payOrderDO
	 */
	boolean refundApply(PayOrderDO payOrderDO);
	/**
	 *
	 * @param payOrderDO
	 * @param refundOrderDO
	 * @return
	 */
	RefundOrderChannelResultDto submitChannelRefundOrder(PayOrderDO payOrderDO ,RefundOrderDO refundOrderDO);
	/**
	 *
	 * @param refundOrderDO
	 * @return
	 */
	RefundOrderChannelResultDto queryChannelRefundOrder(RefundOrderDO refundOrderDO);
	/**
	 *
	 * @param accessCallBody
	 * @param providerChannelConfigDO
	 * @return
	 */
	CommonResult<RefundOrderNotifyDto> refundStatusParse(HttpServletRequest accessCallBody, ProviderChannelConfigDO providerChannelConfigDO);
	/**
	 *
	 * @param channelCode
	 * @param commonResult
	 * @return
	 */
	String callBackResponse(String channelCode, CommonResult commonResult);
	/**
	 *
	 * @param channelCode
	 * @return
	 */
	boolean extensionExist(String channelCode);
}
